import service from '@/utils/request'

// @Tags GameUser
// @Summary 创建GameUser
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.GameUser true "创建GameUser"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
// @Router /gameUser/createGameUser [post]
export const createGameUser = (data) => {
  return service({
    url: '/gameUser/createGameUser',
    method: 'post',
    data
  })
}

// @Tags GameUser
// @Summary 删除GameUser
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.GameUser true "删除GameUser"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /gameUser/deleteGameUser [delete]
export const deleteGameUser = (data) => {
  return service({
    url: '/gameUser/deleteGameUser',
    method: 'delete',
    data
  })
}

// @Tags GameUser
// @Summary 删除GameUser
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body request.IdsReq true "批量删除GameUser"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /gameUser/deleteGameUser [delete]
export const deleteGameUserByIds = (data) => {
  return service({
    url: '/gameUser/deleteGameUserByIds',
    method: 'delete',
    data
  })
}

// @Tags GameUser
// @Summary 更新GameUser
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.GameUser true "更新GameUser"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"更新成功"}"
// @Router /gameUser/updateGameUser [put]
export const updateGameUser = (data) => {
  return service({
    url: '/gameUser/updateGameUser',
    method: 'put',
    data
  })
}

export const updateGameUserPass = (data) => {
  return service({
    url: '/gameUser/updateGameUserPass',
    method: 'put',
    data
  })
}

// @Tags GameUser
// @Summary 用id查询GameUser
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query model.GameUser true "用id查询GameUser"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"查询成功"}"
// @Router /gameUser/findGameUser [get]
export const findGameUser = (params) => {
  return service({
    url: '/gameUser/findGameUser',
    method: 'get',
    params
  })
}

// @Tags GameUser
// @Summary 分页获取GameUser列表
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query request.PageInfo true "分页获取GameUser列表"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
// @Router /gameUser/getGameUserList [get]
export const getGameUserList = (params) => {
  return service({
    url: '/gameUser/getGameUserList',
    method: 'get',
    params
  })
}
